package com.example.feign.controller;

import com.example.feign.service.HiService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class HiController {
    @Autowired
    HiService hiService;
    @GetMapping("/hi")
    public String sayHi(@RequestParam(defaultValue = "forzep",required =  false) String name){
        return hiService.sayHi(name);
    }
    @GetMapping("/get")
    public String sayHitwo(@RequestParam(defaultValue = "forzep-two",required =  false) String name){
        return hiService.sayHitwo(name);
    }
}
